﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Areas/Forum/Views/Shared/Forum1.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<SacNetUG.Areas.Forum.Models.Post>>" %>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

<h4><%: ViewData["SubjectAndResultingPosts"]%></h4>
<span class="userredmessage"><%: TempData["SaveNewPost"] %></span>
<span class="userredmessage"><%: TempData["SaveFlaggedPost"] %></span>
<hr />

<table class="tableofsubjectandpost">
    <tr>
        <td style="width:75px; text-align:left; vertical-align:top;">&nbsp;</td>
        <td style="width:95px; text-align:right; vertical-align:top;">&nbsp;</td>
        <td style="width:60px; text-align:right;">&nbsp;</td>
        <td style="width:82%; text-align:left; vertical-align:top; padding-left:15px; color:Red; font-size:1.0em; font-weight:bold;"><%: ViewData["selectedsubject"]%></td>
    </tr>
    <tr>
        <td style="width:75px; text-align:left; vertical-align:top;">&nbsp;<%: ViewData["postorhandle"]%></td>
        <td style="width:95px; text-align:right; vertical-align:top;"><%: ViewData["dateofpost"]%></td>
        <td style="width:60px; text-align:right;">&nbsp;</td>
        <td style="width:82%; text-align:left; vertical-align:top; padding-left:15px"><%: ViewData["thepost"]%></td>
    </tr>
</table>
<hr />

<table class="tableofresponses">
    <% foreach (var post in Model)
    { %>
        <tr>
            <td style="width:75px; text-align:left; vertical-align:top;">&nbsp;<%: post.PostorHandle%></td>
            <td style="width:95px; text-align:right; vertical-align:top;"><%: post.DatePosted%></td>
            <td style="width:60px; text-align:right; vertical-align:top;"><%: Html.ActionLink("flag", "FlagPostToASubject", "Posts", new { postid = post.PostID, postedto = post.PostedTo }, null)%></td>
            <td style="width:82%; text-align:left; vertical-align:top; padding-left:15px"><%: post.ThePost%></td>
        </tr>
    <% } %>
</table>

<hr />
<div class="activelink">
    <%: Html.ActionLink("Add your post to this Topic for discussion (login required)", "CreateNewPostToASubject", "Posts", new { postedto = ViewData["postedto"] }, null)%>
</div>

</asp:content>
